<template>
	<view>
		<view class="yuan">
			<view style="color: #fff; padding-top: 150rpx; font-size: 150rpx; font-weight: bold;">{{examScore}}</view>
			<view style="color: #31A37A; margin-top: 15rpx;">本次考试得分</view>
		</view>
		<view style="width: 70%; margin: 0 auto; margin-top: 180rpx;">
			<view class="xia" v-for="(item, idx) in shuju">
				<view style="display: flex; align-items: center;">
					<image class="tu" :src="item.img" mode=""></image>
					<view style=" margin-left: 15rpx;">{{item.name}}</view>
				</view>
				<view class="chakan" @click="chakan">点击查看</view>
			</view>
			<view class="zhengshu" @click="zhengshu">查看证书</view>
		</view>

		<gui-popup ref="tanchuang">
			<view class="tanchuang">
				<view style="text-align: center; padding-top: 50rpx;">柳钢新任工会干部培训合格证</view>
				<view style="margin-left: 50rpx; margin-top: 20rpx;">姓名：{{user.chinaname}}</view>
				<view style="margin-left: 50rpx; margin-top: -10rpx;">----------------------------</view>
				<view style="width: 450rpx; margin-left: 50rpx; margin-top: 10rpx; text-indent: 55rpx;">
					该同志通过柳钢集团工会新任工会干部培训考试，成绩合格，特发此证。</view>
				<view style="position: absolute; right: 50rpx; font-size: 19rpx; margin-top: 20rpx;">
					<view style="">广西钢铁集团有限公司工会委员会</view>
					<view style="text-align: center;">发证日期：2024年1月20日</view>
				</view>
			</view>
		</gui-popup>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				user: uni.getStorageSync("member"),
				examScore: '',
				shuju: [{
						id: 0,
						name: '得分统计',
						img: '../../static/certificate/lv.png'
					},
					{
						id: 1,
						name: '试题解析',
						img: '../../static/certificate/cheng.png'
					}
				]
			}
		},
		onLoad(opt) {
			this.examScore = opt.examScore
			console.log('成绩: ', this.examScore);
		},
		methods: {
			close() {
				this.$refs.tanchuang.close();
			},
			chakan() {
				this.$boya.msg('暂未开放')
			},
			zhengshu() {
				this.$boya.msg('暂未开放')
				// this.$refs.tanchuang.open();
			}
		}
	}
</script>

<style>
	.yuan {
		width: 280px;
		height: 280px;
		margin: 0 auto;
		margin-top: 18%;
		text-align: center;
		border-radius: 50%;
		background: radial-gradient(circle at center, #80ECD1, #fff);
		box-shadow: 0 0 30px rgba(0, 0, 0, 0.2);
	}

	.xia {
		font-size: 35rpx;
		display: flex;
		align-items: center;
		justify-content: space-between;
		border-bottom: 1px solid #EDEDED;
		margin-top: 25rpx;
	}

	.tu {
		width: 35rpx;
		height: 40rpx;
		padding: 15rpx;
	}

	.chakan {
		color: #37B190;
		border-bottom: 1px solid #37B190;
		font-size: 25rpx;
	}

	.zhengshu {
		width: 127rpx;
		margin-top: 38rpx;
		margin-left: 398rpx;
		color: #37B190;
		border-bottom: 1px solid #37B190;
		font-size: 32rpx;
	}

	.tanchuang {
		width: 580rpx;
		height: 400rpx;
		font-size: 25rpx;
		background: url('../../static/certificate/zhengshu.png') 100% 100% / 100% 100%;
	}

	.logo {
		width: 180rpx;
		height: 50rpx;
	}
</style>